<?php
namespace Wx\Controller;
use Think\Controller;
class JoinusController extends Controller {
	public function join(){
		
        $this->display();
	}//end fun
	public function add(){
		$joinus=D('joinus');
		$data['type']=$_POST['type'];
		$data['name']=$_POST['name'];
		$data['sex']=$_POST['sex'];
		$data['email']=$_POST['email'];
		$data['tel']=$_POST['tel'];
		$data['address']=$_POST['address'];
		$data['addtime']=time();
		$alt=$joinus->add($data);
		if($alt>0){
			$this->ajaxReturn("OK");
		}else{
			$this->ajaxReturn("err");
		}
	}//end fun
} 